#define DEBUG
#include <cstdio>

using namespace std;

const int maxn=20000000, mods=1000000007;

long long fact[maxn+1], unfact[maxn+1];

long long qpower(long long a, int n) {
  long long s=1;
  for (; n>1; n/=2) {
    if (n%2) {
      s = s*a%mods;
    }
    a = a*a%mods;
  }
  return s*a%mods;
}

void initFact(int n) {
  fact[0] = 1;
  for (int i=1; i<=n; i++) {
    fact[i] = fact[i-1]*i%mods;
  }
  unfact[n] = qpower(fact[n], mods-2);
  for (int i=n; i>0; i--) {
    unfact[i-1] = unfact[i]*i%mods;
  }
}

long long c(int n, int m) {
  if (n<m || n<0 || m<0) {
    return 0;
  }
  return fact[n]*unfact[m]%mods*unfact[n-m]%mods;
}

int main() {
  freopen("tg.in", "r", stdin);
  freopen("tg.out", "w", stdout);

  initFact(maxn+1);

  int t;
  scanf("%d", &t);
  for (int i=1; i<=t; i++) {
    int n, x, y;
    scanf("%d %d %d", &n, &x, &y);
    if (x>y) {
      int t;
      t=x, x=y, y=t;
    }
    int u=y+1, v=x-1;
    long long ans=((c(x+y-2, x-1)+mods-c(u+v-2, u-1))%mods*((c(2*n-x-y, n-x)+mods-c(2*n-u-v, n-u))%mods))%mods;
    printf("%lld\n", ans);
  }

  fclose(stdin);
  fclose(stdout);
  return 0;
}
